package com.ruoyi.applet.service.impl;

import java.util.List;

import com.ruoyi.applet.domain.Goods;
import com.ruoyi.applet.domain.vo.ProductSpecifications;
import com.ruoyi.applet.domain.vo.UsrBrowseVo;
import com.ruoyi.applet.domain.vo.UsrLikeBrowse;
import com.ruoyi.applet.domain.vo.UsrOrder;
import org.springframework.stereotype.Service;
import com.ruoyi.applet.mapper.GoodsMapper;
import com.ruoyi.applet.service.IGoodsService;

import javax.annotation.Resource;

/**
 * 商品Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-11-14
 */
@Service
public class GoodsServiceImpl implements IGoodsService 
{
    @Resource
    private GoodsMapper goodsMapper;


    @Override
    public List<UsrBrowseVo> selectAllByGoodsImgIdList(Long usrId) {
        return goodsMapper.selectAllByGoodsImgIdList(usrId);
    }

    @Override
    public List<UsrBrowseVo> selectAllByGoodsIdList(Long goodsId) {
        return goodsMapper.selectAllByGoodsIdList(goodsId);
    }

    @Override
    public Goods selectAllByGoodsId(Long goodsId) {
        return goodsMapper.selectAllByGoodsId(goodsId);
    }

    @Override
    public ProductSpecifications selectAllByGoodsIdSpecifications( String specValue1, String specValue2, String specValue3, Long goodsId) {
        return goodsMapper.selectAllByGoodsIdSpecifications(specValue1, specValue2, specValue3, goodsId);
    }

    @Override
    public UsrLikeBrowse selectAllByImagesUrlUsrLikeBrowse(Long goodsId) {
        return goodsMapper.selectAllByImagesUrlUsrLikeBrowse(goodsId);
    }

    @Override
    public UsrOrder selectAllByProductSpecId(Long productSpecId) {
        return goodsMapper.selectAllByProductSpecId(productSpecId);
    }
}
